//
//  UIButton+GYBtn.m
//  LockManagement
//
//  Created by apple on 2018/8/22.
//  Copyright © 2018年 yunjiazhineng. All rights reserved.
//

#import "UIButton+GYBtn.h"

@implementation UIButton (GYBtn)

+ (instancetype)buttonWithFrame:(CGRect)frame backGroundImage:(NSString *)backGroundImageName tag:(NSInteger)tag target:(id)target action:(SEL)action {
    UIButton *btn = [[UIButton alloc] initWithFrame:frame];
    btn.tag = tag;
    [btn addTarget:target action:action forControlEvents:UIControlEventTouchUpInside];
    [btn setBackgroundImage:[UIImage imageNamed:backGroundImageName] forState:UIControlStateNormal];
    
    return btn;
}
@end
